#include <stdio.h>
#include <math.h>

#define noop {}

int main(void) {
    while (1) {
        int n;
        scanf("%d", &n);
        if (n == 0) {
            break;
        }
        int layer = 0;
        int layer_min_count, layer_max_count;
        while (1) {
            layer_min_count = layer * layer + 1;
            layer_max_count = (layer + 1) * (layer + 1);
            //printf("layers: %d, min: %d, max: %d\n", layer, layer_min_count, layer_max_count);
            if (layer_min_count <= n && n <= layer_max_count) {
                break;
            }
            layer++;
        }
        int last_drawn_count = 0;
        int all_drawn_count = 0;
        for (int i = 0; i <= layer; i++) {
            last_drawn_count = 0;
            int drawn_count = 0;
            for (int sp = 0; sp < layer - i; sp++) {
                putchar(' ');
            }
            for (int j = 0; j <= i; j++) {
                putchar('/');
                putchar('\\');
                drawn_count++;
                all_drawn_count++;
                if (all_drawn_count >= n) {
                    last_drawn_count = drawn_count;
                    if (n == 2 || n == 5) putchar('/');
                    putchar('\n');
                    goto middle;
                }
            }
            putchar('\n');
            last_drawn_count = drawn_count;
        }
        middle:
        for (int i = 0; i < last_drawn_count; i++) {
            putchar('\\');
            putchar('/');
        }
        putchar('\n');
        if (all_drawn_count >= n) {
            goto end;
        }
        for (int i = 1; i <= layer; i++) {
            for (int sp = 0; sp < i; sp++) {
                putchar(' ');
            }
            int drawn_count = 0;
            last_drawn_count = 0;
            for (int j = 0; j <= layer - i; j++) {
                putchar('\\');
                putchar('/');
                drawn_count++;
                all_drawn_count++;
                if (all_drawn_count >= n) {
                    last_drawn_count = drawn_count;
                    putchar('\n');
                    goto end;
                }
            }
            putchar('\n');
            last_drawn_count = drawn_count;
        }
        end:
        noop;
    }
    return 0;
}
